<template>
	<div class="teamBox">
		<div  v-if='num>0'>
			<div class="list flex-col" >
				<div class="title">用户名: 135XXXX5698</div>
				<div class="time">注册日：2020-02-18</div>
			</div>
		</div>
	<div v-if='num==0' class='textCenter paddingtb20'>暂无数据</div>
		
	</div>
</template>

<script>
	export default{
		data(){
			return{
				dataList:[],
				num:0,
				currentPage:1,
				size:20,
			}
		},
		mounted() {
		this.getTeam()	
		},
		methods:{
			getTeam(){
				let id = uni.getStorageSync('userId')
				this.$http.get('/userCenter/getMyTeamList', {size:this.size,current:this.currentPage,id:id}).then(res => {
					if (res.code == '0') {
						this.dataList = res.data
							
						if(res.data.length){
								this.num = res.data.length
						}else{
								this.num = 0
						}
					
					}else{
						uni.showToast({
							icon:"none",
							title:res.msg
						})
					}
				})
			},
			
		}
	}
</script>

<style scoped lang="scss">
	
	.teamBox{
		padding: 0 30upx;
		background: #fff;
		.list{
			padding: 30upx 0;
			background: #fff;
			border-bottom: 1upx solid rgba(238,238,238,1);
			&:last-child{
				border-bottom: none;
			}
			.title{
				font-size: 30upx;
				color: #22222A;
				padding-bottom: 28upx;
			}
			.time{
				font-size: 24upx;
				color: #9A9a9a;
			}
		}
	}
</style>
